package personal.xjl._23java1studentdemo.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

@Controller
@RequestMapping("Sutdent")
public class StudentController {

    @RequestMapping("list")
    @ResponseBody
    public String list(){
        System.out.println("list");
        return "list";
    }
    //<h1>java1</h1>
    @RequestMapping("addStudent")
    @ResponseBody
    public String add(){
        System.out.println("addStudent");
        return "<h1>addStudent</h1>";
    }
}
